/*!
 * LaTeX prism.css (https://latex.vercel.app/#syntax-highlighting)
 * Based on the default prism.js theme for JavaScript, CSS and HTML by Lea Verou
 *
 * Source: https://github.com/vincentdoerig/latex-css/tree/master/prism
 * Licensed under MIT (https://github.com/vincentdoerig/latex-css/blob/master/LICENSE)
*/

:root {
  --bg-color: #F0F0F0;
  --color: black;
  --token-teal: #407f80;
  --token-black: #000000;
  --token-grey: #666666;
  --token-green: #007f00;
  --token-lime: #7d8f29;
  --token-brown: #9a6e3a;
  --token-red: #ba2121;
  --token-fuchsia: #dd4a68;
  --token-orange: #e90;
  --token-pink: #BA6687;
}

.latex-dark {
  --bg-color: #2d2d2d;
  --color: #ccc;
  --token-teal: #90D0D0;
  --token-black: #ccc;
  --token-grey: #999;
  --token-green: #51B53F;
  --token-lime: #B4C55D;
  --token-brown: #D3A26B;
  --token-red: #FA5E4F;
  --token-fuchsia: #FF839B;
  --token-orange: #FFCF4C;
  --token-pink: #F49BBC;
}

@media (prefers-color-scheme: dark) {
  .latex-dark-auto {
    --bg-color: #2d2d2d;
    --color: #ccc;
    --token-teal: #90D0D0;
    --token-black: #ccc;
    --token-grey: #999;
    --token-green: #51B53F;
    --token-lime: #B4C55D;
    --token-brown: #D3A26B;
    --token-red: #FA5E4F;
    --token-fuchsia: #FF839B;
    --token-orange: #FFCF4C;
    --token-pink: #F49BBC;
  }
}

code[class*='language-'],
pre[class*='language-'] {
  color: var(--color);
  background: none;
  text-align: left;
  white-space: pre;
  word-spacing: normal;
  word-break: normal;
  word-wrap: normal;
  line-height: 1.5;

  -moz-tab-size: 4;
  -o-tab-size: 4;
  tab-size: 4;

  -webkit-hyphens: none;
  -moz-hyphens: none;
  -ms-hyphens: none;
  hyphens: none;
}


/* Code blocks */
pre[class*='language-'] {
  padding: 1em;
  overflow: auto;
}

pre[class*='language-'] {
  background: var(--bg-color);
}

/* Inline code */
:not(pre) > code[class*='language-'] {
  padding: 0.1em;
  border-radius: 0.3em;
  white-space: normal;
}

:not(pre) > code[class*='language-'].break-all {
  word-break: break-all;
}

.token.comment,
.token.prolog,
.token.doctype,
.token.cdata {
  color: var(--token-teal);
}

.token.punctuation,
.token.constant {
  color: var(--token-black);
}

.token.punctuation.attr-equals,
.token.number,
.token.operator {
  color: var(--token-grey);
}

.token.namespace {
  opacity: 0.7;
}

.token.property,
.token.tag,
.token.boolean,
.token.symbol,
.token.deleted,
.token.keyword {
  color: var(--token-green);
}

.token.selector,
.token.attr-name,
.token.char,
.token.builtin,
.token.inserted {
  color: var(--token-lime);
}

.token.entity,
.token.url,
.language-css .token.string,
.style .token.string {
  color: var(--token-brown);
}

.token.atrule,
.token.attr-value,
.token.string,
.token.attr-value .punctuation:not(.attr-equals) {
  color: var(--token-red);
}

.token.class-name {
  color: var(--token-fuchsia);
}

.token.important,
.token.variable {
  color: var(--token-orange);
}

.token.regex {
  color: var(--token-pink);
}

.token.important,
.token.bold {
  font-weight: bold;
}
.token.italic {
  font-style: italic;
}

.token.entity {
  cursor: help;
}
